var express = require("express");
const {
  findById,
  login,
  login1,
  register,
  updateById,
  deleteById,
} = require("../controller/users_controller");
var router = express.Router();

router.get("/:id", findById); //get  http://127.0.0.1:3000/users/6166b04027addbc5401760a4
router.post("/login", login); //post http://127.0.0.1:3000/users/login     {username:admin,password:username}
router.post("/login1", login1); //post http://127.0.0.1:3000/users/login1     {username:admin,password:username}
router.post("/register", register); //post http://127.0.0.1:3000/users/register     {username:test,password:test}
router.put("/:id", updateById); //put http://127.0.0.1:3000/6166b04027addbc5401760a4     {username:test1,password:123456}
router.delete("/:id", deleteById); //delete  http://127.0.0.1:3000/users/6166b04027addbc5401760a4

module.exports = router;
